#pragma once

namespace ysimple_network
{
	struct ITCPSession;

	struct IConnectCallback
	{
		virtual void				onConnected(ITCPSession& session, bool success) = 0;
	};

	struct IAcceptCallback
	{
		virtual void				onAccepted(ITCPSession& listenSession, ITCPSession& newSession) = 0;
	};

	struct ISendCallback
	{
		virtual void				onSent(ITCPSession& session, bool success, size_t sentLength) = 0;
	};

	struct IRecvCallback
	{
		virtual void				onRecved(ITCPSession& session, bool success, const char* recvedData, size_t recvedLength) = 0;
	};

	struct IDisconectCallback
	{
		virtual void				onDisconnected(ITCPSession& session) = 0;
	};

	struct ICancelIOCallback
	{
		virtual void				onCanceled(ITCPSession& session) = 0;
	};
}